import MedicalRecords from '@/panels/PanelMedicalRecords';
import HospitalManage from '@/panels/PanelHospitalManage';
import LabManage from '@/panels/PanelLabManage';
import InsuranceManage from '@/panels/PanelInsuranceManage';
import System from '@/panels/PanelSystem';

// import axios from '../utils/axios'
// import { useState, useEffect } from 'react';

interface MainContentProps {
  activeMenu: number; // 使用枚举类型
}

export default function MainContent({ activeMenu }: MainContentProps) {
  // const navigate = useNavigate();

  const getContent = () => {
    switch (activeMenu) {
      case 1:
        return <MedicalRecords />;
      case 2:
        return <HospitalManage />;
      case 3:
        return <LabManage />;
      case 4:
        return <InsuranceManage />;
      case 5:
        return <System />;
      default:
        return null;
    }
  };

  return (
    <div className="flex-1 overflow-auto bg-gray-50 p-6">
      {getContent()}
    </div>
  );
}
